﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;

namespace Faust.Andrew.MTG.Player
{
    class Program
    {
        static void Main(string[] args)
        {
            using (ServiceHost serviceHost = new ServiceHost(typeof(MTGServer), new Uri("net.tcp://localhost:4200")))
            {
                NetTcpBinding binding = new NetTcpBinding();
                binding.MaxBufferPoolSize = Int32.MaxValue;
                binding.MaxBufferSize = Int32.MaxValue;
                binding.MaxConnections = 300;
                binding.MaxReceivedMessageSize = Int32.MaxValue;

                serviceHost.AddServiceEndpoint(typeof(Shared.IMTGServer), binding, "net.tcp://localhost:4200");

                serviceHost.Open();

                Console.WriteLine("Service Started. Press Enter to Exit.");
                Console.ReadLine();
            }
        }
    }
}
